package com.github.bridge.client.esign;

import lombok.Data;
import org.springframework.http.HttpStatus;

@Data
public class ESignResult<T> {

    private Integer status;

    private Integer code;

    private String message;

    private T data;

    public boolean success() {
        if (code == null) {
            return HttpStatus.OK.value() == status;
        }
        return HttpStatus.OK.value() == code;
    }
}
